const TokenKey = 'hmtt-token'

const saveToken = obj => {
  localStorage.setItem(TokenKey, JSON.stringify(obj))
}
const getToken = () => {
  return JSON.parse(localStorage.getItem(TokenKey))
}
const removeToken = () => {
  localStorage.removeItem(TokenKey)
}
export { saveToken, removeToken, getToken }
